package unitTesting;

import static org.junit.Assert.*;

import java.util.ArrayList;

import org.junit.Test;

public class SearchTest 
{
	beans.DAOCLass testDAO = new beans.DAOCLass();

	ArrayList<String> testList = new ArrayList<>();
	@Test
	public void testGetData() 
	{
		testList.add("Finest Sencha 125g/1");
		testList.add("Finest Sencha 125g/4");
		
		assertEquals(testList, testDAO.getData("finest", "0"));
	}
	@Test
	public void testSearchCategory()
	{
		testList.add("Finest Sencha 125g/4");
		testList.add("Lipton Green Tchae 250g/5");
		testList.add("Mao Feng 250g/6");
		
		assertEquals(testList, testDAO.getData("loose", "2"));
	}
}